<extend name="Layout/ins_page" />
<block name="content">
	{:W('PageHeader/simple',array('name'=>'系统参数'))}
	<div class="layui-tab layui-tab-brief" >
		<ul class="layui-tab-title">
			<li class="layui-this">
				<a href="#">基本设置</a>
			</li>
			<li>
				<a  href="{:U('weixin')}">微信设置</a>
			</li>
			<li>
				<a  href="{:U('weixin_menu')}">微信菜单</a>
			</li>
			<li>
				<a href="{:U('config')}">系统参数</a>
			</li>
			<li>
				<a href="{:U('push')}">推送设置</a>
			</li>
		</ul>
	</div>
	<div class="sub-frame gray">
		<form id="form_system" name="form_system" method="post" >
			<input type="hidden" name="data_type" value="system">
			<div class="layui-sub-form-item ">
				<label class="layui-form-label" for="code">系统名称*：</label>
				<div class="layui-input-block">
					<input class="layui-input" type="text" id="system_name" name="system_name" check="required" info="请输入系统名称" value="{$system_data.system_name}">
				</div>
			</div>
			<div class="layui-sub-form-item ">
				<label class="layui-form-label text-right" for="system_license">授权码：</label>
				<div class="layui-input-block">
					<input class="layui-input" type="text" id="system_license" name="system_license" value="{$system_data.system_license}" >
				</div>
			</div>
			<div class="layui-sub-form-item ">
				<label class="layui-form-label text-right" for="upload_file_ext">上传文件类型*：</label>
				<div class="layui-input-block">
					<input class="layui-input" type="text" id="upload_file_ext" name="upload_file_ext" value="{$system_data.upload_file_ext}">
				</div>
			</div>
			<div class="layui-sub-form-item ">
				<label class="layui-form-label text-right">登录验证码：</label>
				<div class="layui-input-block">
					<span class="x-checkbox">
						<input type="checkbox" value="1" name="login_verify_code" <eq name="system_data.login_verify_code" value="1">checked</eq> >
					</span>
					开启
				</div>
			</div>
			<div class="layui-sub-form-item ">
				<label class="layui-form-label"></label>
				<div class="layui-input-block">
					<a id="btn_save_system" class="btn">保存</a>
				</div>
			</div>
		</form>
	</div>
</block>
<block name="js">
	<script type="text/javascript">
		layui.use('global', function() {
			var $ = layui.jquery;

			$("#btn_save_system").on('click', function() {
				send_form("form_system", "{:U('save')}", "{:U('index')}", function(ret) {
					if (ret.status) {
						layer.msg(ret.info, {
							time : 1200
						}, function() {
							location.reload(true);
						});

					} else {
						layer.msg(ret.info);
						return false;
					}
				});
			});
		});
	</script>
</block>